<!DOCTYPE html><!-- 显示每个Category内容 -->
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<div th:replace="common/top">
</div>

<div id="Content">
    <div id="Catalog">
        <h2 th:text="${categoryId}">categoryId</h2>

        <table class="altrowstable">
            <tr>
                <th>Product ID</th>
                <th>Name</th>
                <th>Operation</th>
            </tr>
            <tr th:each="productlist,productlistStat:${productList}">
                <td><a th:href="'/catalog/viewItems?productId='+${productList.get(productlistStat.index).getProductId()}" th:text="${productList.get(productlistStat.index).getProductId()}"></a></td>
                <td th:text="${productList.get(productlistStat.index).getName()}"></td>
                <td><a class="Button" th:href="'/catalog/deleteProduct?productId='+${productList.get(productlistStat.index).getProductId()}">删除</a></td>
            </tr>
        </table>
        <a class="Button" th:href="'/catalog/newProductForm?categoryId='+${categoryId}" th:text="新增商品">新增商品</a>

        <a class="Button" th:href="'/catalog/deleteCategory?categoryId=' + ${categoryId}" th:text="删除该类">delete</a>

    </div>
</div>

<div th:replace="common/bottom">
</div>
</body>
</html>